package com.ebeijia.mybatis.mapper;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;

import com.ebeijia.dto.BindUserDto;
import com.ebeijia.mybatis.pojo.UserInfo;
import com.ebeijia.query.MemberQuery;

public interface UserInfoMapper {
	/***
	 * 根据openId查询数据 
	 * @param openid
	 * @return
	 */
	UserInfo getUserByopenId(String openid);
	
	/**
	 * 测试 游标返回数据 
	 * @param map
	 * @return
	 */
	List<Map<String, Object>> TestCURSOR(Map<String, Object> map);
	/**
	 * 根据openId
	 * @param openId
	 * @return
	 */
	List<UserInfo> getOpenId(String openId);
	
	UserInfo getUserId(String userNo);
	
    int deleteByPrimaryKey(String openid);

    int insert(UserInfo user);

    int insertSelective(UserInfo record);

    UserInfo selectByPrimaryKey(String id);

    int updateByPrimaryKeySelective(UserInfo record);

    int updateByPrimaryKey(UserInfo record);
    
    UserInfo selectByParams(@Param(value = "params") Map<String, Object> params);


    List<BindUserDto> queryBindUser(MemberQuery memberQuery);

    int queryBindUserCount(MemberQuery memberQuery);

    List<BindUserDto> selectUserList(MemberQuery memberQuery);

    int selectUserListCount(MemberQuery memberQuery);


    List<UserInfo> selectByPrimaryUserNo(String userNo);
}